package com.info.zhiduoduo.repository.entity.company;

import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.experimental.Accessors;

/**
 * <p>
 * 
 * </p>
 *
 * @author bob
 * @since 2021-01-08
 */
@Data
@Accessors(chain = true)
@TableName("zdd_crowdsource_monthly_deposit_record")
public class CrowdsourceMonthlyDepositRecord extends Model<CrowdsourceMonthlyDepositRecord> {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;
    /**
     * 企业id
     */
    private Integer compid;
    /**
     * 返回月份
     */
    private Date month;
    /**
     * 企业基础税率
     */
    @TableField("base_tax_rate")
    private Double baseTaxRate;
    /**
     * 第二档额度
     */
    @TableField("secondary_monthly_amount")
    private BigDecimal secondaryMonthlyAmount;
    /**
     * 保证金比例
     */
    @TableField("deposit_rate")
    private Double depositRate;
    /**
     * 第二档保证金比例
     */
    @TableField("secondary_deposit_rate")
    private Double secondaryDepositRate;
    /**
     * 实际返回比例
     */
    @TableField("actual_deposit_rate")
    private Double actualDepositRate;
    /**
     * 交易额(不含税)
     */
    @TableField("project_amount")
    private BigDecimal projectAmount;
    /**
     * 已收税费(不含保证金)
     */
    @TableField("project_tax_fee")
    private BigDecimal projectTaxFee;
    /**
     * 应返保证金
     */
    @TableField("should_return_deposit")
    private BigDecimal shouldReturnDeposit;
    /**
     * 实返保证金
     */
    @TableField("actual_return_deposit")
    private BigDecimal actualReturnDeposit;
    /**
     * 状态 1:待结算 2:已结算
     */
    private Integer state;

    @ApiModelProperty("线上返回：0(默认)，线下返回：1")
    @TableField("is_online")
    private int isOnline;
    /**
     * 结算时间
     */
    @TableField("return_time")
    private Date returnTime;
    /**
     * 结算操作人
     */
    private Integer adminid;
    private Date createtime;
    private Date updatetime;


    @Override
    protected Serializable pkVal() {
        return this.id;
    }

}
